﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;

namespace Algobox.JuicyLib.Cryptography.GnuPGWrapper
{
    /// <summary>
    /// Specific exception thrown whenever a PGP error occurs.
    /// 
    /// <p/>This class is a simple derivation from the Exception class.
    /// </summary>
    public class GnuPGException : Exception
    {
        /// <summary>
        /// Constructor
        /// </summary>
        /// <param name="message">error message associated with exception</param>
        public GnuPGException(string message)
            : base(message)
        {
        }
    }

    /// <summary>
    /// List (enum) of available commands (sign, encrypt, sign and encrypt, etc...)
    /// </summary>
    public enum Commands
    {
        /// <summary>
        /// Make a signature
        /// </summary>
        Sign,
        /// <summary>
        /// Encrypt  data
        /// </summary>
        Encrypt,
        /// <summary>
        /// Sign and encrypt data
        /// </summary>
        SignAndEncrypt,
        /// <summary>
        /// Decrypt data
        /// </summary>
        Decrypt,
        /// <summary>
        /// Assume that input is a signature and verify it without generating any output
        /// </summary>
        Verify
    };
    // TODO implement other GPG commands (--clearsign, --detach-sign, --symmetric, --store, --verify-files, --encrypt-files, --decrypt-files, --list-keys, --list-public-keys, --list-secret-keys, --list-sigs, --check-sigs, --fingerprint, --check-sigs, --list-packets, --gen-key, --edit-key, --sign-key, --lsign-key, --nrsign-key, --delete-key, --delete-secret-key, --delete-secret-and-public-key, --gen-revoke, --desig-revoke, --export, --send-keys, --export-all, --export-secret-keys, --export-secret-subkeys, --import, --fast-import, --recv-keys, --search-keys, --update-trustdb, --check-trustdb, --export-ownertrust, --import-ownertrust, --rebuild-keydb-caches, --print-md, --print-mds, --gen-random, --gen-prime mode, --version, --warranty, --help)

    /// <summary>
    /// List (enum) of available verbose levels (NoVerbose, Verbose, VeryVerbose)
    /// </summary>
    public enum VerboseLevel
    {
        /// <summary>
        /// Reset verbose level to 0 (no information shown during processing)
        /// </summary>
        NoVerbose,
        /// <summary>
        /// Give more information during processing.
        /// </summary>
        Verbose,
        /// <summary>
        /// Give full information during processing (the input data is listed in detail).
        /// </summary>
        VeryVerbose
    };
}
